package gxdlxy.zx2201.chat5;

public class Example6 {
    public static void main(String[] args) {
        System.out.println(Math.random()); // 0-1之间随机数

        int[] a = new int[52];
        for (int i = 0; i < 100000; i++) {
            // 产生13-51之间的随机数
            int rnd = (int)(Math.random() * 38 + 13);
            a[rnd]++;

        }
        for (int i = 1; i < a.length; i++) {
            if ((i - 1) % 6 == 0) System.out.println();
            System.out.print(i + ":" + a[i] + "   ");
        }
    }
}
